﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.Collections.ObjectModel;
using System.Collections.Generic;

namespace MainGameModule.ViewModels
{
    public class MapGenerator
    {
        public Action<object> MapLoaded;
        private static MapGenerator instance;
        
        private MapGenerator()
        {
        }

        public static MapGenerator Instance
        {
            get
            {
                if ( instance == null )
                    instance = new MapGenerator();

                return instance;
            }
        }
        
        private Dictionary<int, List<int>> MapRegionsCollection
        {
            get;
            set;
        }

        /// <summary>
        /// Loads all the regions in the map
        /// </summary>
        /// <param name="regionId">the Region's Id</param>
        public void LoadMap( int regionId )
        {
            //make the call to the service to load the mesh
            //When the loading is succeeded create a Region and add it to the RegionsDefinitions collection
        }
        
        public string GetRegionBackground( int regionId )
        {
            return "";
        }
    }
}
